// Copyright (c) 2009 Luca Marrocco.
// Modified or written by Luca Marrocco for inclusion with codej.
// Licensed under the Apache License, Version 2.0 (the "License")
package codej.ast;


/** @author Luca Marrocco */
public class CompilationUnit extends AbstractNode {
	
	private String packageName;

	public void accept(Visitor visitor) {
		visitor.visit(this);
	}

	public CompilationUnit addImportDeclaration(ImportDeclaration importDeclaration) {
		addChild(importDeclaration);
		return this;
	}

	public CompilationUnit addTypeDeclaration(TypeDeclaration typeDeclaration) {
		addChild(typeDeclaration);
		return this;
	}

	public String getPackageName() {
		return packageName;
	}

	public CompilationUnit setPackageName(String packageName) {
		this.packageName = packageName;
		return this;
	}

	public void setAnnotations(Annotations annotations) {
		addChild(annotations);
	}
}
